#!/bin/sh
#desc:Dummy logevent file
#type:restricted
LOGFILE="/var/log/events.log"
tstamp=`date +%H:%M:%S`

if ! test -f "$LOGFILE"; then
	# After bootstart it should call this script as a Root
	if test `whoami` = "root"; then
		touch $LOGFILE
		chown admin:admin $LOGFILE
		chmod 0622 $LOGFILE	
	fi
fi

if test "$1" = "--help" || test -z "$1"; then
	echo "usage: $0 level package message"
else
	echo "$tstamp	$2.$1	$3 $4" >> $LOGFILE
fi
